package com.atguigu.bridge;

/**
 * @program: design-patterns
 * @author: yangshen
 * @description: 客户端-执行
 * @create: 2022-02-16 10:57
 **/
public class Client {
    public static void main(String[] args) {
        //获取折叠式手机（样式 + 品牌）
        System.out.println("------------折叠式手机-----------------");
        FolderPhone folderPhone = new FolderPhone(new XiaoMi());
        folderPhone.open();
        folderPhone.close();
        folderPhone.call();
        System.out.println("-------------");
        FolderPhone folderPhone1 = new FolderPhone(new Vivo());
        folderPhone1.open();
        folderPhone1.close();
        folderPhone1.call();
        System.out.println("------------直立式手机------------");
        UpRightPhone upRightPhone = new UpRightPhone(new XiaoMi());
        upRightPhone.open();
        upRightPhone.close();
        upRightPhone.call();
        System.out.println("-------------");
        UpRightPhone upRightPhone1 = new UpRightPhone(new Vivo());
        upRightPhone1.open();
        upRightPhone1.close();
        upRightPhone1.call();
    }
}
